﻿using System.Linq;
using XRM.Security.DataAccess.Models;

namespace XRM.Security.DataAccess.Repositories.Impl
{
    public class IdentityCenterRepository : BaseRepository<IdentityCenter>
    {
        public IdentityCenter GetByName(string issuerName)
        {
            return GetAll( s => s.IdentityCenterName == issuerName ).FirstOrDefault();
        }

        public IQueryable<IdentityCenter> GetActual()
        {
            return GetAll( s => !s.IsDeleted );
        }
    }
}
